#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/types.h>
#include <fcntl.h>
#include <sys/stat.h>

int main(int argc, char **argv)
{
	int fd;
	int value;

	fd = open("/dev/led_driver", O_WRONLY);
	if(fd < 0)
	{
		perror("cannot open device led");
		exit(1);
	}	
	while(1)
	{
		/* ?? LED */
		value = 1;
		write(fd, &value, 4);
		sleep(1);
		
		/* ?? LED */
		value = 0;
		write(fd, &value, 4);
		sleep(1);
	}
	close(fd);
	return 0;

}
